<div id="qrcode"></div>
<script src="https://cdn.jsdelivr.net/gh/davidshimjs/qrcodejs@gh-pages/qrcode.min.js"></script>
<script>
const now = new Date();
    const hours = now.getHours();
const minutes = now.getMinutes();
    let targetUrl;
    // 早上8:00-12:00
    const isMorning = (hours === 8 && minutes >= 0) || 
                     (hours > 8 && hours < 12) || 
                     (hours === 12 && minutes === 0);
    // 下午14:30-17:30
    const isAfternoon = (hours === 14 && minutes >= 30) || 
                       (hours > 14 && hours < 17) || 
                       (hours === 17 && minutes <= 30);
    // 设置不同时间段的跳转链接
if(isMorning ){
window.location.href = "https://work.weixin.qq.com/kfid/kfcc30d6413cb207572";
}if(isAfternoon){
window.location.href = "https://work.weixin.qq.com/kfid/kfcc00bcc5e142dffc4";
}
   /* if (hours >= 8 && hours < 12) {
        targetUrl = "https://work.weixin.qq.com/kfid/kfcc30d6413cb207572";
    } else if (hours >= 14.5 && hours <17.5) {
        targetUrl = "https://work.weixin.qq.com/kfid/kfcc00bcc5e142dffc4";
    } */
//new QRCode(document.getElementById("qrcode"), targetUrl);
</script>